﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Volo.Abp.Domain.Entities;

namespace mozhi.smarterp.AuthorCenter.ApiMetadatas
{
    public class ApiMetadata : AggregateRoot<Guid>
    {
        public string Path { get; private set; }

        public string Method { get; private set; }

        public string ApiScope { get; private set; }

        public ApiMetadata(Guid id, string path, string method, string apiScope)
        {
            Id = id;
            Path = path?.ToLower();
            Method = method?.ToLower();
            ApiScope = apiScope;
        }

        public void Change(string path ,string method , string apiScope)
        {
            Path = path;
            Method = method;
            ApiScope = apiScope;
        }
    }
}
